<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .txt{
            background-color: lavender;
            border: none;
            height: 40px;
            outline: none;
            vertical-align: top;
        }
        .but{
            background-color: rgb(214, 214, 248);
            height: 42px;
            border: none;
            margin-left: -5px;
            border-left: 1px solid gray;
        }
        div{
            border: 1px solid gray;
            float: left;
            background-color: yellow;
            margin-top: 10px;
        }
    </style>
</head>
<body>
    <div>
        <input type="text" class="txt">
        <input type="button" value="按钮" class="but">
        <!-- 1.按钮和输入框不涉及边框问题，设置按钮高度逼输入框高度多2px即可 -->
         <!-- 2.按钮和输入框设计的时候，给外包一个div设置一个border -->
    </div>
</body>
</html>